import Vue from 'vue'
import Vuex from 'vuex'
import counter from './modules/counter'
import shopcart from './modules/shopcart'
Vue.use(Vuex)
const store=new Vuex.Store({
    state:{},
    mutations:{},
    actions:{},
    modules:{
        counterKey:counter,
        shopcartKey:shopcart
    }
})
export default store

/**
 * vuex模块化的实现步骤
 * 1、首先在store/modules下创建模块文件
 */